﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Caliburn.Micro;
using GTServices.Entities;
using System.Windows.Data;

using GTServices.WPF.Client.Interfaces;


namespace GTServices.WPF.Client.ViewModels.Entities
{
    public class ClassificationViewModel : PropertyChangedBase, IEntityViewModel
    {
        private Classification _classification;
        public Classification Classification { 
            get { return _classification; } 
            set {
                _classification = value;
                NotifyOfPropertyChange(() => Classification); 
            } 
        }

        public String ReferenceUrl
        {
            get { return Classification.ReferenceUrl; }
            set
            {
                Classification.ReferenceUrl = value;
                NotifyOfPropertyChange(() => ReferenceUrl);
            }
        }

        public String Name
        {
            get { return Classification.Name; }
            set
            {
                Classification.Name = value;
                NotifyOfPropertyChange(() => Name);
            }
        }
        public String Description
        {
            get { return Classification.Description; }
            set
            {
                Classification.Description = value;
                NotifyOfPropertyChange(() => Description);
            }
        }

        public Object Model
        {
            get { return Classification; }
            set
            {
                if (value is Classification)
                    Classification = value as Classification;
            }
        }
    }
}
